ALL = 1000
final = []
for LIMIT in range(1,ALL+1):
    answers = set()
    for a in range(1,LIMIT+1):
        for b in range(1,(LIMIT+1)-a):
            c = LIMIT - (a+b)
            if c**2 == (a**2 + b**2):
                ans = [a,b,c]
                ans.sort()
                ans = tuple(ans)
                answers.add(ans)
    final.append(len(answers))
max_value = max(final)
i = final.index(max_value)+1
print(str(i)+": "+str(max_value))